{extend name="public:base" /}

{block name="content"}
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <a href="{:url(doSeckill)}" class="btn btn-primary btn-lg">新增</a>
                    <div class="ibox-tools">
                        <a class="collapse-link">
                            <i class="iconfont icon-chevron-up"></i>
                        </a>
                    </div>
                </div>

                <div class="ibox-content">
                    <div class="table-responsive">
                        <table class="table table-striped">
                            <tr>
                                <th>ID</th>
                                <th>秒杀商品</th>
                                <th>秒杀时间</th>
                                <th>秒杀价格</th>
                                <th>秒杀数量</th>
                                <th>操作</th>
                            </tr>
                            {volist name="list" id="vo"}
                            <tr>
                                <td>{$vo.id}</td>
                                <td>{$vo.goods_name}</td>
                                <td>{$vo.start_time|timeFormat} - {$vo.end_time|timeFormat}</td>
                                <td>{$vo.price}</td>
                                <td>{$vo.count}</td>
                                <td>
                                    <a href="{:url(doSeckill, ['id' => $vo.id])}" class="btn btn-white btn-sm"><i class="iconfont icon-edit"></i>
                                        编辑 </a>
                                    <a href="{:url(delSeckill, ['id' => $vo.id])}" class="btn btn-white btn-sm ajax-del"><i class="iconfont icon-trash"></i> 删除
                                    </a>
                                </td>
                            </tr>
                            {/volist}
                        </table>
                        {if !empty($list)}{$list->render()}{/if}
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
{/block}
